<html>

<head>
	<title>Logbook4Task5</title>
</head>

<body>

	<form method="POST" action="d.php">
		Your name
		<input type="text" name="name">
		<br>
		Marks in Networks and protocols assignment (from 20%)
		<input type="text" name="value1">
		<br>
		Marks in Networks and Protocols Exam (80%)
		<input type="text" name="value2">
		<br>
		<input type="submit" name="submit" value="Check total marks">
	</form>

<?php

	if(isset($_POST["submit"]))
	{
		$value1 = $_POST["value1"];
		$value2 = $_POST["value2"];

		echo "<b>Your result is:</b><br>";
		echo (($value1*2)+($value2*8))/10;
	}

?>

</body>
</html>
